<template>
  <view>
    <cu-custom bgColor="bg-gradual-green" :isBack="true">
      <block slot="backText">返回</block>
      <block slot="content">柔韧性</block>
    </cu-custom>
    <view class="contents u-f-ajc u-f-column">
      <view>坐姿提前屈</view>

      <view class="t-a-c" style="margin-top: 120rpx;">
        <view style="font-size: 34rpx;">距离</view>
        <view class="kedu">{{kedu}}cm</view>
        <slide-choose :width="70" :bigItemWidth="2" :littleItemWidth="2" @change="chooseChange" :defaultNum="20" height="200rpx"
          :cellWidth="10" :cells="10" :cellNum="0.1" :startNum="-40" :endNum="50" color="#39BB9E" :bigItemHeight="40"
          :littleItemHeight="20" selColor="#0ff" align="flex-start" numPos="bottom"></slide-choose>
      </view>

      <view @click="confirm" style="position: fixed;bottom: 50rpx;left: 10%; z-index: 99; width: 80%;height: 80upx;line-height: 80upx;text-align: center;background-color: #39BB9E;color: #fff;font-size: 32upx;border-radius: 10rpx;">
        保存
      </view>
    </view>
  </view>
</template>

<script>
  import slideChoose from "../../../components/dlm-slide-choose/dlm-slide-choose.vue"
  export default {
    components: {
      slideChoose
    },
    data() {
      return {
        kedu: 20,
      }
    },
    methods: {
      chooseChange(e) {
        console.log(e)
        this.kedu = e
      },
      goPage() {
        let url = `../add_assessment`;
        uni.redirectTo({
          url
        })
      },
      confirm() {
        let objs = uni.getStorageSync('fmsDetails2')
        objs.list3 = this.kedu
        uni.setStorageSync('fmsDetails2', objs)
        this.goPage();
      },
    }
  }
</script>

<style lang="scss">
  page {
    background-color: #4B505F !important;
  }

  .contents {
    padding: 30rpx;
    color: #FFFFFF;
  }

  .kedu {
    color: #39BB9E;
    font-size: 46rpx;
    font-weight: 600;
    margin: 30rpx 0 20rpx;
  }
</style>
